package com.wuming.house.service;

import com.wuming.house.core.BusinessException;
import com.wuming.house.model.HouseImg;

import java.util.List;

public interface HouseImgService {

    /**
     * 保存楼盘图片信息
     *
     * @param hi 楼盘图片
     * @throws BusinessException
     */
    void saveHouseImg(HouseImg hi) throws BusinessException;

    /**
     * 根据楼盘id查询楼盘图片信息
     *
     * @param houseId   楼盘id
     * @param houseType 楼盘类型
     * @return 楼盘图片
     * @throws BusinessException
     */
    List<HouseImg> getHouseImgByHouseId(Long houseId, Integer houseType, int pageIndex, int pageSize) throws BusinessException;

    /**
     * 查询图片总数
     *
     * @param houseId   楼盘id
     * @param houseType 楼盘总数
     * @return 图片总数
     * @throws BusinessException
     */
    int getTotal(Long houseId, Integer houseType) throws BusinessException;

    void deleteById(Long id) throws BusinessException;
}
